package com.kerrykidz.system.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.kerrykidz.membership.dao.mapper.CusClassImpDtlEntityMapper;
import com.kerrykidz.membership.dao.model.CusClassImpDtlEntity;
import com.kerrykidz.system.service.ICusClassImpDtlService;
import com.rdp.framework.exception.RDPException;

@Service
public class CusClassImpDtlServiceImpl implements ICusClassImpDtlService{
	@Autowired
	private CusClassImpDtlEntityMapper dtlEntityMapper;
	/**
	 * 查询学员签到信息
	 * 
	 * @param 
	 *            
	 * @return
	 * @throws RDPException
	 */
	@Override
	public CusClassImpDtlEntity findSignMsg(CusClassImpDtlEntity dtlEntity)
			throws RDPException {
		dtlEntity.setIspaging(true);
		List<CusClassImpDtlEntity> beanList = dtlEntityMapper.findSignMsg(dtlEntity);
		if(beanList.size()>0){
			dtlEntity.setResults(beanList);
		}
		return dtlEntity;
	}
	
	/**
	 * 添加课程签到表导入明细
	 * 
	 * @param 
	 *            
	 * @return
	 * @throws RDPException
	 */
	@Override
	public void insertSignMsg(CusClassImpDtlEntity dtlEntity)
			throws RDPException {
		dtlEntityMapper.insertSignMsg(dtlEntity);;
	}

	/**
	 * 查找签到历史
	 * 
	 * @param 
	 * @return 
	 *            
	 * @return
	 * @throws RDPException
	 */
	@Override
	public List<CusClassImpDtlEntity> signedHistory(CusClassImpDtlEntity dtlEntity)
			throws RDPException {
		List<CusClassImpDtlEntity> beanlist =  dtlEntityMapper.signedHistory(dtlEntity);
		return beanlist;
	}

	@Override
	public CusClassImpDtlEntity findReSigned(
			CusClassImpDtlEntity dtlEntity) throws RDPException {
		
		return dtlEntityMapper.findReSigned(dtlEntity);
	}
	

}
